package sctu.edu.java.year2016.team01.zhuming.day20160530.Practice;

/**  局部类部类。
 * Created by Administrator on 2016/6/1.
 */
public class Apple {

    private String name;

    public Apple(){

        name="香蕉";
    }
    public void sell(int price){
         class Bannaner {
             int innerprince;

             public Bannaner(int price) {

                 innerprince = price;
             }

             public void dell() {

                 System.out.println("现在开始销售：" + name);
                 System.out.println(name + "的价格是" + price);
             }

         }
        Bannaner bannaner = new Bannaner(8);
         bannaner.dell();
    }
            public static void main(String[] args){

                Apple apple=new Apple();

                apple.sell(8);


    }
    }







